#
#  Be sure to run `pod spec lint CAICategories.podspec' to ensure this is a
#  valid spec and to remove all comments including this before submitting the spec.
#
#  To learn more about Podspec attributes see https://guides.cocoapods.org/syntax/podspec.html
#  To see working Podspecs in the CocoaPods repo see https://github.com/CocoaPods/Specs/
#

Pod::Spec.new do |spec|

  spec.name         = "ZXCategories"
  spec.version      = "0.2.0"
  spec.summary      = "这是chs的老CAICategories，司机端，销售端，商户端都在使用的老分类。"

  # This description is used to generate tags and improve search results.
  #   * Think: What does it do? Why did you write it? What is the focus?
  #   * Try to keep it short, snappy and to the point.
  #   * Write the description between the DESC delimiters below.
  #   * Finally, don't worry about the indent, CocoaPods strips it!
  spec.description  = <<-DESC
            这是chs的Categories，司机端，销售端，商户端都在使用的老分类。
                   DESC

  spec.homepage     = "https://gitee.com/zj1208/ZXCategories"
  # spec.screenshots  = "www.example.com/screenshots_1.gif", "www.example.com/screenshots_2.gif"
  spec.license      = { :type => "MIT", :file => "LICENSE" }
  spec.author             = { "海参" => "879654715@qq.com" }
  # Or just: spec.author    = "海参"
  # spec.authors            = { "海参" => "879654715@qq.com" }
  # spec.social_media_url   = "https://twitter.com/海参"

  # ――― Platform Specifics ――――――――――――――――――――――――――――――――――――――――――――――――――――――― #
  #
  #  If this Pod runs only on iOS or OS X, then specify the platform and
  #  the deployment target. You can optionally include the target after the platform.
  #

  spec.platform     = :ios
  spec.ios.deployment_target = "9.0"
  
  spec.source       = { :git => "https://gitee.com/zj1208/ZXCategories.git", :tag => "#{spec.version}" }

  spec.source_files  = "ZXCategories/Classes/{CAICategories,NullSafe}.{h,m}"
  spec.exclude_files = "ZXCategories/Classes/Exclude"
  spec.public_header_files = "ZXCategories/Classes/CAICategories.h"

  spec.subspec 'CALayer' do |ss|
     ss.source_files = 'ZXCategories/Classes/CALayer/**/*.{h,m}'
  end

  spec.subspec 'Foundation' do |ss|
    ss.source_files = 'ZXCategories/Classes/Foundation/{NSArray+CHSCategory,NSArrayDictionary+CHSLog,NSData+ZXCategory,NSDecimalNumber+ZXCategory,NSFileManager+ZXCategory,NSNotificationCenter+ZXCategory,NSObject+ZXCategory,NSString+ZXCategory,NSURL+ZXCatetory,NSURLComponents+ZXCategory}/{**}/*.{h,m}'
    ss.subspec 'NSDate+CAICategory' do |sss|
       sss.source_files     = 'ZXCategories/Classes/Foundation/NSDate+CAICategory/{**}/*.{h,m}'
    end
  end

  spec.subspec 'Runtime' do |ss|
     ss.source_files = 'ZXCategories/Classes/Runtime/**/*.{h,m}'
  end

  spec.subspec 'UIKitCore' do |ss|
     ss.source_files = 'ZXCategories/Classes/UI/**/*.{h,m}'
     ss.dependency 'ZXCategories/Runtime'
  end
  
  spec.subspec 'CAIUIImageUtils' do |ss|
     ss.source_files     = 'ZXCategories/Classes/CAIUIImageUtils/**/*'
  end
  
  # spec.public_header_files = "Classes/**/*.h"


  # spec.resource  = "icon.png"
  # spec.resources = "Resources/*.png"

  # spec.preserve_paths = "FilesToSave", "MoreFilesToSave"


  # ――― Project Linking ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――― #
  #
  #  Link your library with frameworks, or libraries. Libraries do not include
  #  the lib prefix of their name.
  #

  # spec.framework  = "SomeFramework"
  # spec.frameworks = "SomeFramework", "AnotherFramework"

  # spec.library   = "iconv"
  # spec.libraries = "iconv", "xml2"


  # ――― Project Settings ――――――――――――――――――――――――――――――――――――――――――――――――――――――――― #
  #
  #  If your library depends on compiler flags you can set them in the xcconfig hash
  #  where they will only apply to your library. If you depend on other Podspecs
  #  you can include multiple dependencies to ensure it works.

  # spec.requires_arc = true

  # spec.xcconfig = { "HEADER_SEARCH_PATHS" => "$(SDKROOT)/usr/include/libxml2" }
  # spec.dependency "JSONKit", "~> 1.4"

end
